//
//  UIImage+NED.h
//  MoreCoin
//
//  Created by 林宁宁 on 2019/10/22.
//  Copyright © 2019 MoreCoin. All rights reserved.
//


#import <UIKit/UIKit.h>

NS_ASSUME_NONNULL_BEGIN

@interface UIImage (NED)

/** 改变图片的主颜色*/
- (UIImage *)ned_drawColor:(UIColor*)color;

/** 修正图片的方向*/
- (UIImage *)ned_fixOrientation;

- (UIImage *)ned_darker;


//============== 图片裁剪
- (UIImage *)ned_resizedImage:(CGSize)newSize
        interpolationQuality:(CGInterpolationQuality)quality;
- (UIImage *)ned_resizedImageWithContentMode:(UIViewContentMode)contentMode
                                     bounds:(CGSize)bounds
                       interpolationQuality:(CGInterpolationQuality)quality;
- (UIImage *)ned_circleImage;



- (UIColor*)ned_maimColor;


- (UIImage *)ned_compression500KB;


- (UIImage *)ned_compressionLength:(NSInteger)maxLength;

- (NSData *)ned_compressImageAimWidth:(CGFloat)width
                           aimHeight:(CGFloat)height
                           aimLength:(NSInteger)length
                    accuracyOfLength:(NSInteger)accuracy;

@end

NS_ASSUME_NONNULL_END
